Optimal. Leaf size=153 \[ \frac {(A+B) \cos (e+f x)}{4 f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}}+\frac {(A-B) \cos (e+f x)}{4 c f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{3/2}}+\frac {(A-B) \tanh ^{-1}(\sin (e+f x)) \cos (e+f x)}{4 c^2 f \sqrt {a+a \sin (e+f x)} \sqrt {c-c \sin (e+f x)}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.25, antiderivative size = 153, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 40, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {3051, 2822,
2820, 3855} \begin {gather*} \frac {(A-B) \cos (e+f x) \tanh ^{-1}(\sin (e+f x))}{4 c^2 f \sqrt {a \sin (e+f x)+a} \sqrt {c-c \sin (e+f x)}}+\frac {(A-B) \cos (e+f x)}{4 c f \sqrt {a \sin (e+f x)+a} (c-c \sin (e+f x))^{3/2}}+\frac {(A+B) \cos (e+f x)}{4 f \sqrt {a \sin (e+f x)+a} (c-c \sin (e+f x))^{5/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2820
Rule 2822
Rule 3051
Rule 3855
Rubi steps
\begin {align*} \int \frac {A+B \sin (e+f x)}{\sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}} \, dx &=\frac {(A+B) \cos (e+f x)}{4 f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}}+\frac {(A-B) \int \frac {1}{\sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{3/2}} \, dx}{2 c}\\ &=\frac {(A+B) \cos (e+f x)}{4 f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}}+\frac {(A-B) \cos (e+f x)}{4 c f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{3/2}}+\frac {(A-B) \int \frac {1}{\sqrt {a+a \sin (e+f x)} \sqrt {c-c \sin (e+f x)}} \, dx}{4 c^2}\\ &=\frac {(A+B) \cos (e+f x)}{4 f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}}+\frac {(A-B) \cos (e+f x)}{4 c f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{3/2}}+\frac {((A-B) \cos (e+f x)) \int \sec (e+f x) \, dx}{4 c^2 \sqrt {a+a \sin (e+f x)} \sqrt {c-c \sin (e+f x)}}\\ &=\frac {(A+B) \cos (e+f x)}{4 f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{5/2}}+\frac {(A-B) \cos (e+f x)}{4 c f \sqrt {a+a \sin (e+f x)} (c-c \sin (e+f x))^{3/2}}+\frac {(A-B) \tanh ^{-1}(\sin (e+f x)) \cos (e+f x)}{4 c^2 f \sqrt {a+a \sin (e+f x)} \sqrt {c-c \sin (e+f x)}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.42, size = 222, normalized size = 1.45 \begin {gather*} \frac {\left (A+B+(A-B) \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )^2+(-A+B) \log \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right ) \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )^4+(A-B) \log \left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right ) \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )^4\right ) \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right ) \left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right )}{4 f \sqrt {a (1+\sin (e+f x))} (c-c \sin (e+f x))^{5/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(470\) vs.
\(2(135)=270\).
time = 0.34, size = 471, normalized size = 3.08
method | result | size |
default | \(\frac {\left (A \left (\cos ^{2}\left (f x +e \right )\right ) \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )-A \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right ) \left (\cos ^{2}\left (f x +e \right )\right )-B \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right ) \left (\cos ^{2}\left (f x +e \right )\right )+B \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right ) \left (\cos ^{2}\left (f x +e \right )\right )+2 A \sin \left (f x +e \right ) \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )-2 A \sin \left (f x +e \right ) \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )+2 A \left (\cos ^{2}\left (f x +e \right )\right )-2 B \sin \left (f x +e \right ) \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )+2 B \sin \left (f x +e \right ) \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )-2 A \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )+2 A \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )+3 A \sin \left (f x +e \right )+2 B \ln \left (-\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )-2 B \ln \left (-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}\right )+B \sin \left (f x +e \right )-2 A \right ) \cos \left (f x +e \right )}{4 f \sqrt {a \left (1+\sin \left (f x +e \right )\right )}\, \left (-c \left (\sin \left (f x +e \right )-1\right )\right )^{\frac {5}{2}}}\) | \(471\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.44, size = 456, normalized size = 2.98 \begin {gather*} \left [-\frac {{\left ({\left (A - B\right )} \cos \left (f x + e\right )^{3} + 2 \, {\left (A - B\right )} \cos \left (f x + e\right ) \sin \left (f x + e\right ) - 2 \, {\left (A - B\right )} \cos \left (f x + e\right )\right )} \sqrt {a c} \log \left (-\frac {a c \cos \left (f x + e\right )^{3} - 2 \, a c \cos \left (f x + e\right ) + 2 \, \sqrt {a c} \sqrt {a \sin \left (f x + e\right ) + a} \sqrt {-c \sin \left (f x + e\right ) + c} \sin \left (f x + e\right )}{\cos \left (f x + e\right )^{3}}\right ) - 2 \, {\left ({\left (A - B\right )} \sin \left (f x + e\right ) - 2 \, A\right )} \sqrt {a \sin \left (f x + e\right ) + a} \sqrt {-c \sin \left (f x + e\right ) + c}}{8 \, {\left (a c^{3} f \cos \left (f x + e\right )^{3} + 2 \, a c^{3} f \cos \left (f x + e\right ) \sin \left (f x + e\right ) - 2 \, a c^{3} f \cos \left (f x + e\right )\right )}}, -\frac {{\left ({\left (A - B\right )} \cos \left (f x + e\right )^{3} + 2 \, {\left (A - B\right )} \cos \left (f x + e\right ) \sin \left (f x + e\right ) - 2 \, {\left (A - B\right )} \cos \left (f x + e\right )\right )} \sqrt {-a c} \arctan \left (\frac {\sqrt {-a c} \sqrt {a \sin \left (f x + e\right ) + a} \sqrt {-c \sin \left (f x + e\right ) + c}}{a c \cos \left (f x + e\right ) \sin \left (f x + e\right )}\right ) - {\left ({\left (A - B\right )} \sin \left (f x + e\right ) - 2 \, A\right )} \sqrt {a \sin \left (f x + e\right ) + a} \sqrt {-c \sin \left (f x + e\right ) + c}}{4 \, {\left (a c^{3} f \cos \left (f x + e\right )^{3} + 2 \, a c^{3} f \cos \left (f x + e\right ) \sin \left (f x + e\right ) - 2 \, a c^{3} f \cos \left (f x + e\right )\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {A + B \sin {\left (e + f x \right )}}{\sqrt {a \left (\sin {\left (e + f x \right )} + 1\right )} \left (- c \left (\sin {\left (e + f x \right )} - 1\right )\right )^{\frac {5}{2}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.55, size = 263, normalized size = 1.72 \begin {gather*} -\frac {\frac {2 \, {\left (A \sqrt {a} \sqrt {c} - B \sqrt {a} \sqrt {c}\right )} \log \left (-\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + 1\right )}{a c^{3} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )} - \frac {4 \, {\left (A \sqrt {a} \sqrt {c} - B \sqrt {a} \sqrt {c}\right )} \log \left ({\left | \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right ) \right |}\right )}{a c^{3} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )} + \frac {2 \, {\left (A \sqrt {a} \sqrt {c} - B \sqrt {a} \sqrt {c}\right )} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + A \sqrt {a} \sqrt {c} + B \sqrt {a} \sqrt {c}}{a c^{3} \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \mathrm {sgn}\left (\sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{4}}}{16 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {A+B\,\sin \left (e+f\,x\right )}{\sqrt {a+a\,\sin \left (e+f\,x\right )}\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{5/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________